# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=tokei
pkgver=12.0.4
pkgrel=0
pkgdesc="A blazingly fast CLOC (Count Lines Of Code) program"
url="https://github.com/XAMPPRocky/tokei"
arch="all !s390x !mips !mips64" # limited by cargo
license="MIT AND Apache-2.0"
makedepends="rust cargo"
source="$pkgname-$pkgver.tar.gz::https://github.com/XAMPPRocky/tokei/archive/v$pkgver.tar.gz"

build() {
	cargo build --release --locked --features all
}

check() {
	cargo test --release --locked --features all
}

package() {
	install -Dm755 target/release/tokei "$pkgdir"/usr/bin/tokei
}

sha512sums="f5810ca93746f4e269a60eaad0cd07950a54a0c5b73c7256f79ae882373ebe733af25adaf7ed133a9e591ab2bfafd170a20669b80a1e09acc283e1ecbd98626e  tokei-12.0.4.tar.gz"
